home *** CD-ROM | disk | FTP | other *** search
/ Freelog 22 / freelog 22.iso / Prog / Djgpp / GPC2952B.ZIP / lib / gcc-lib / djgpp / 2.952 / units / strings.pas < prev    next >
Encoding:
Pascal/Delphi Source File  |  2001-02-08  |  3.5 KB  |  73 lines

  1. {
  2. BP compatible Strings unit
  3.  
  4. Copyright (C) 1999-2001 Free Software Foundation, Inc.
  5.  
  6. Author: Frank Heckenbach <frank@pascal.gnu.de>
  7.  
  8. This file is part of GNU Pascal.
  9.  
  10. GNU Pascal is free software; you can redistribute it and/or modify
  11. it under the terms of the GNU General Public License as published by
  12. the Free Software Foundation; either version 2, or (at your option)
  13. any later version.
  14.  
  15. GNU Pascal is distributed in the hope that it will be useful,
  16. but WITHOUT ANY WARRANTY; without even the implied warranty of
  17. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  18. GNU General Public License for more details.
  19.  
  20. You should have received a copy of the GNU General Public License
  21. along with GNU Pascal; see the file COPYING. If not, write to the
  22. Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
  23. 02111-1307, USA.
  24.  
  25. As a special exception, if you link this file with files compiled
  26. with a GNU compiler to produce an executable, this does not cause
  27. the resulting executable to be covered by the GNU General Public
  28. License. This exception does not however invalidate any other
  29. reasons why the executable file might be covered by the GNU General
  30. Public License.
  31. }
  32.  
  33. {$gnu-pascal,B-,I-}
  34.  
  35. unit Strings;
  36.  
  37. interface
  38.  
  39. uses GPC;
  40.  
  41. function  StrLen     (Src : CString) : SizeType;                            asmname '_p_strlen';
  42. function  StrEnd     (Src : CString) : CString;                             asmname '_p_strend';
  43. function  StrMove    (Dest, Source : CString; Count : SizeType) : CString;  asmname '_p_strmove';
  44. function  StrCopy    (Dest, Source : CString) : CString;                    asmname '_p_strcpy';
  45. function  StrECopy   (Dest, Source : CString) : CString;                    asmname '_p_strecpy';
  46. function  StrLCopy   (Dest, Source : CString; MaxLen : SizeType) : CString; asmname '_p_strlcpy';
  47. function  StrPCopy   (Dest : CString; const Source : String) : CString;     asmname '_p_cstringcopystring';
  48. function  StrCat     (Dest, Source : CString) : CString;                    asmname '_p_strcat';
  49. function  StrLCat    (Dest, Source : CString; MaxLen : SizeType) : CString; asmname '_p_strlcat';
  50. function  StrComp    (s1, s2 : CString) : Integer;                          asmname '_p_strcmp';
  51. function  StrIComp   (s1, s2 : CString) : Integer;                          asmname '_p_strcasecmp';
  52. function  StrLComp   (s1, s2 : CString; MaxLen : SizeType) : Integer;       asmname '_p_strlcmp';
  53. function  StrLIComp  (s1, s2 : CString; MaxLen : SizeType) : Integer;       asmname '_p_strlcasecmp';
  54. function  StrScan    (Src : CString; Ch : Char) : CString;                  asmname '_p_strscan';
  55. function  StrRScan   (Src : CString; Ch : Char) : CString;                  asmname '_p_strrscan';
  56. function  StrPos     (aString, SubString : CString) : CString;              asmname '_p_strpos';
  57. function  StrRPos    (aString, SubString : CString) : CString;              asmname '_p_strrpos';
  58. function  StrUpper   (s : CString) : CString;                               asmname '_p_strupper';
  59. function  StrLower   (s : CString) : CString;                               asmname '_p_strlower';
  60. function  StrPas     (aString : CString) : TString;                         asmname '_p_strpas';
  61. function  StrEmpty   (s : CString) : Boolean;                               asmname '_p_strempty';
  62. function  StrNew     (Src : CString) : CString;                             asmname '_p_strdup';
  63. procedure StrDispose (s : CString);                                         asmname '_p_dispose';
  64.  
  65. implementation
  66.  
  67. function StrPas (aString : CString) : TString;
  68. begin
  69.   StrPas := CString2String (aString)
  70. end;
  71.  
  72. end.
  73.